<form class="form-horizontal" id="form-edit-user">
    <div class="form-group">
        <label class="control-label col-xs-2">
            用户名
            <span style="color: #FF0000;">*</span>
        </label>
        <div class="col-xs-9">
            {$info.username}
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            会员等级：
            <span style="color: #FF0000;">*</span>
        </label>
        <div class="col-xs-9">
            <select class="form-control" name="levelid" id="levelid" required>
                <option value=''>全部</option>
                {volist name='catelist' id='cv'}
                <option value='{$cv.id}' {if $cv.id eq $info.levelid}selected{/if}>{$cv.title}</option>
                {/volist}
            </select>
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            推荐人手机号：
        </label>
        <div class="col-xs-9">
            {$info.tui_selfphone}
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            真实姓名：

        </label>
        <div class="col-xs-9">
            <input type="text" value="{$info.realname}"  class="form-control" placeholder="请输入真实姓名" name="realname" autocomplete="off">

        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            手机号
            <span style="color: #FF0000;">*</span>
        </label>
        <div class="col-xs-9">
            <input type="number" value="{$info.selfphone}" required class="form-control" placeholder="请输入手机号" name="selfphone" autocomplete="off">
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-2">
            二级密码
        </label>
        <div class="col-xs-9">
            <input type="text" class="form-control" name="sepasswd" placeholder="请输入二级密码" >
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            登录状态
        </label>
        <div class="col-xs-9">
            <input name="is_active" type="radio" value="1" {if condition="$info['is_active'] eq 1" }checked="checked" {/if}  />可以登录
            &nbsp;&nbsp;&nbsp;&nbsp;
            <input name="is_active" type="radio" value="2" {if condition="$info['is_active'] eq 2" }checked="checked" {/if} />不可登录
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            是否设为官方号
        </label>
        <div class="col-xs-9">
            <input name="is_our" type="radio" value="1" {if condition="$info['is_our'] eq 1" }checked="checked" {/if}  />不是官方号
            <input name="is_our" type="radio" value="2" {if condition="$info['is_our'] eq 2" }checked="checked" {/if}  />是官方号
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            不可描述
        </label>
        <div class="col-xs-9">
            <input name="hello" type="radio" value="1" {if condition="$info['hello'] eq 1" }checked="checked" {/if}  />正常
            <input name="hello" type="radio" value="2" {if condition="$info['hello'] eq 2" }checked="checked" {/if}  />禁止
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            开户银行
        </label>
        <div class="col-xs-9">
            <input type="text" value="{$info.bankname}"  class="form-control" placeholder="请输入开户银行" name="bankname" autocomplete="off">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            银行卡号
        </label>
        <div class="col-xs-9">
            <input type="number" value="{$info.bankcard}"  class="form-control" placeholder="请输入银行卡号" name="bankcard" autocomplete="off">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            转账激活
        </label>
        <div class="col-xs-9">
            <input name="user_status" type="radio" value="1" {if condition="$info['user_status'] eq 1" }checked="checked" {/if}  />已转账激活
            &nbsp;&nbsp;&nbsp;&nbsp;
            <input name="user_status" type="radio" value="0" {if condition="$info['user_status'] eq 0" }checked="checked" {/if} />未转账激活
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            身份证
        </label>
        <div class="col-xs-9">
            <input type="number" value="{$info.selfcard}"  class="form-control" placeholder="请输入身份证" name="selfcard" autocomplete="off">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            团队人数
        </label>
        <div class="col-xs-9">
            <input type="number" value="{$info.teamcount}"  class="form-control" placeholder="请输入团队人数" name="teamcount" autocomplete="off">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            直推人数
        </label>
        <div class="col-xs-9">
            <input type="number" value="{$info.pidcount}"  class="form-control" placeholder="请输入直推人数" name="pidcount" autocomplete="off">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            是否固定等级
        </label>
        <div class="col-xs-9">
            <label><input type="radio" {if $info.is_levfix eq 2}checked{/if} value="2" name="is_levfix">是</label>
            <label><input type="radio" {if $info.is_levfix eq 1}checked{/if} value="1" name="is_levfix">否</label>
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            合约收益
        </label>
        <div class="col-xs-9">
            <input type="number" value="{$info.myprofit}"  class="form-control" placeholder="请输入合约收益" name="myprofit" autocomplete="off">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            团队收益
        </label>
        <div class="col-xs-9">
            <input type="number" value="{$info.pushs}"  class="form-control" readonly> <i>如需修改请到"会员钱包"修改</i>
        </div>
    </div>


    <div class="form-group">
        <label class="control-label col-xs-2">
            支付宝账号
        </label>
        <div class="col-xs-9">
            <input type="text" value="{$info.email}"  class="form-control" placeholder="请输入支付宝账号" name="email" autocomplete="off">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-2">
            微信号
        </label>
        <div class="col-xs-9">
            <input type="text" value="{$info.selfqq}"  class="form-control" placeholder="请输入微信号" name="selfqq" autocomplete="off">
        </div>
    </div>
    <div class="form-group">
        <div class="col-xs-offset-2 col-xs-3">
            <button type="submit" class="btn btn-success btn-block">确认编辑</button>
        </div>
    </div>
</form>

<script src="__PUBLIC__/vendors/jquery.validation/jquery.validate.min.js"></script>
<script src="__PUBLIC__/vendors/jquery.validation/additional-methods.js"></script>
<script src="__PUBLIC__/vendors/jquery.validation/messages_zh.min.js"></script>
<script type="application/javascript">
    $(function () {
        $("#form-edit-user").validate({
            messages:
                {
                    selfphone:"请填写手机号",
                    username:"请填写用户名",
                },
            debug: true,
            submitHandler: function () {
                ajaxSubmit('form-edit-user', true);
            }
        });
    })
</script>
<script src="__PUBLIC__/vendors/select2/js/select2.min.js"></script>
<script type="application/javascript">
    $(function () {
        $("#levelid").select2({
            placeholder: "当前等级",
            allowClear: true
        });
    });
</script>
